package com.caijing.caijingxueyuanxd.controller;

import com.caijing.caijingxueyuanxd.entity.Manager;
import com.caijing.caijingxueyuanxd.service.ManagerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@CrossOrigin
public class ManagerController {

    //注入service
    @Autowired
    private ManagerService service;
    @GetMapping("/manager")
    public List<Manager> selectAll(){
        return service.selectAll();
    }


}
